package bill.study;

public class AutoBoxingBug {
	
	public static void main(String args []){
		
		Integer i = new Integer (1);
		Integer j = new Integer (1);
		
		Integer i1 = Integer.valueOf(1);
		Integer j1 = Integer.valueOf(1);
		
		boolean ij= (i == j);
		boolean ij1 = (i1 == j1);
		
		System.out.println("ij is " + ij);
		System.out.println("ij1 is " + ij1);
		
		long l = new Long(1);
		Long ll = new Long(1);
		
		boolean areTheyEqual = l== ll;
		
		System.out.println("areTheyEqual is " + areTheyEqual);
		
//		Boolean boo =null;
//		String s = "y";
//		String nu = null;
//		System.out.println("this should return false  : " + s.equals(null));
//		
//		System.out.println("this should throw NPE  : " + nu.equals(s));
//		if(boo){
//			System.out.print("");
//		}
	}

}
